]> dgit.raspbian.org Git - gnome-shell.git/commitdiff
Suppress animation for titles in overview
authorSebastien Lafargue <slaf66@gmail.com>
Thu, 3 Oct 2013 21:08:59 +0000 (23:08 +0200)
committerAdel Gadllah <adel.gadllah@gmail.com>
Thu, 10 Oct 2013 06:51:13 +0000 (08:51 +0200)
Because of the animation and collision with relayout, the title of windows in overview may not appear, mainly
the first time we enter in overview

With an animation delay of 0.1s, you'll not see the difference

https://bugzilla.gnome.org/show_bug.cgi?id=709392

js/ui/workspace.js

index 52a737c2c1c55e5e3253b816a6e3f6d0740cf02c..75683ba6577ebb66a2f9bbfaaa91cc28f035475a 100644 (file)
@@ -343,19 +343,6 @@ const WindowOverlay = new Lang.Class({
             this._animateVisible();
     },
 
-    fadeIn: function() {
-        if (!this._hidden)
-            return;
-
-        this.show();
-        this.title.opacity = 0;
-        this._parentActor.raise_top();
-        Tweener.addTween(this.title,
-                         { opacity: 255,
-                           time: CLOSE_BUTTON_FADE_TIME,
-                           transition: 'easeOutQuad' });
-    },
-
     chromeHeights: function () {
         return [Math.max(this.borderSize, this.closeButton.height - this.closeButton._overlap),
                 this.title.height + this.title._spacing];
@@ -372,7 +359,6 @@ const WindowOverlay = new Lang.Class({
         let border = this.border;
 
         Tweener.removeTweens(button);
-        Tweener.removeTweens(title);
         Tweener.removeTweens(border);
 
         let [cloneX, cloneY, cloneWidth, cloneHeight] = this._windowClone.slot;
@@ -1142,7 +1128,7 @@ const Workspace = new Lang.Class({
                 clone.actor.set_scale(scale, scale);
                 clone.actor.set_opacity(255);
                 clone.overlay.relayout(false);
-                this._showWindowOverlay(clone, overlay, isOnCurrentWorkspace);
+                this._showWindowOverlay(clone, overlay);
             }
         }
     },
@@ -1172,23 +1158,19 @@ const Workspace = new Lang.Class({
                            time: Overview.ANIMATION_TIME,
                            transition: 'easeOutQuad',
                            onComplete: Lang.bind(this, function() {
-                               this._showWindowOverlay(clone, overlay, true);
+                               this._showWindowOverlay(clone, overlay);
                            })
                          });
 
         clone.overlay.relayout(true);
     },
 
-    _showWindowOverlay: function(clone, overlay, fade) {
+    _showWindowOverlay: function(clone, overlay) {
         if (clone.inDrag)
             return;
 
-        if (overlay) {
-            if (fade)
-                overlay.fadeIn();
-            else
+        if (overlay && overlay._hidden)
                 overlay.show();
-        }
     },
 
     _delayedWindowRepositioning: function() {